/*
 * @Author: sunli
 * @Date: 2024-02-21 14:36:56
 * @LastEditors: sunli
 * @LastEditTime: 2024-02-21 20:07:08
 * @FilePath: /debug-server/DBmodels/errorReport.js
 * @Description: 
 */

const mongoose = require('mongoose')
// const schema = new mongoose.Schema({
//   userName: {type: String, require: true}, // 用户名
//   mobile: {type: String, require: true},
//   email: {type: String, require: true},
//   password: {type: String, require: true}
//   }
// )

mongoose.model('errorReport', {
  _id: String,
  KEY: String,
  title: String, // 页面标题
  url: String, // 页面URL
  timestamp: Number, // 访问时间戳
  userAgent: String, // 用户浏览器类型
  kind: String, // 大类
  type: String, // 小类
  errorType: String, // 错误类型
  message: String, // 类型详情
  filename: String, // 访问的文件名
  position: String, // 行列信息
  stack: String, // 堆栈信息
  selector: String, // 选择器

  // * promiseError

  //  * resourceError
  tagName: String, //标签名
})
